#!/bin/bash
function sum()
{
s=0
if [ $1 -le $2 ];then
for i in `seq $1 $2` 
do
   s=`expr $s + $i`
done
echo $s
else
for i in `seq $2 $1`
do
   s=`expr $s + $i`
done
echo $s
fi
}
sum $1 $2
